package com.example.entity;

import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import lombok.EqualsAndHashCode;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;

@Data
@EqualsAndHashCode(callSuper = true)
@TableName("dish")
@Schema(description = "菜谱实体")
public class Dish extends BaseEntity {
    
    @Schema(description = "菜品ID")
    private Long id;
    
    @Schema(description = "所属食堂ID")
    private Long canteenId;
    
    @Schema(description = "菜品名称")
    @NotBlank(message = "菜品名称不能为空")
    private String name;
    
    @Schema(description = "菜品图片URL")
    @NotBlank(message = "菜品图片不能为空")
    private String imageUrl;
    
    @Schema(description = "制作视频URL")
    private String videoUrl;
    
    @Schema(description = "菜品简介")
    private String description;
    
    @Schema(description = "营养成分")
    private String nutrition;
    
    @Schema(description = "价格")
    @NotNull(message = "价格不能为空")
    private Double price;
    
    @Schema(description = "状态：0-下架，1-上架")
    private Integer status;
} 